package com.sinothk.server.support.xml;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

// ================================= 属性配置
//首先定义一个普通的pojo
//加入如下两个注解
@Component  //让spring容器可以扫描到这个类
@ConfigurationProperties(prefix = "sinothk.gateway")
//让这个类和配置文件关联起来  prefix 是指定的前缀 将来提示时可以通过 logs. 来提示类里的属性
public class GatewayConfig {

    private SubService services;

    public SubService getServices() {
        return services;
    }

    public void setServices(SubService services) {
        this.services = services;
    }

    static class SubService {
        // 基础服务名称
        private String serviceUser;
        private String serviceSystem;
        private String serviceFile;
        private String serviceSearch;
        // 业务服务
        private String serviceBiz;
        // 扩展服务名称
//        private String service01;

        public String getServiceUser() {
            return serviceUser;
        }

        public void setServiceUser(String serviceUser) {
            this.serviceUser = serviceUser;
        }

        public String getServiceSystem() {
            return serviceSystem;
        }

        public void setServiceSystem(String serviceSystem) {
            this.serviceSystem = serviceSystem;
        }

        public String getServiceFile() {
            return serviceFile;
        }

        public void setServiceFile(String serviceFile) {
            this.serviceFile = serviceFile;
        }

        public String getServiceSearch() {
            return serviceSearch;
        }

        public void setServiceSearch(String serviceSearch) {
            this.serviceSearch = serviceSearch;
        }

        public String getServiceBiz() {
            return serviceBiz;
        }

        public void setServiceBiz(String serviceBiz) {
            this.serviceBiz = serviceBiz;
        }
    }
}
